package seatiger.tomcat.coyote;

import seatiger.tomcat.util.buf.ByteChunk;

import java.io.IOException;

/**
 * 输出缓冲区，所有从tomcat的写出都应该实现这个接口
 */
public interface OutputBuffer {

    /**
     * 写出数据
     * @param chunk
     * @param response
     * @return
     * @throws IOException
     */
    int doWrite(ByteChunk chunk,Response response) throws IOException;
}
